<template>
  <div>
    <h1>下拉选择器</h1>
    <el-select v-model="qwe">
      <el-option label="区域1" value="北京">北京</el-option>
      <el-option label="区域2" value="天津">天津</el-option>
      <el-option label="区域3" value="上海">上海</el-option>
      <el-option label="区域4" value="广州">广州</el-option>
    </el-select>
    <h1>使用远程数据回显下拉列表</h1>
     <el-select v-model="asd" placeholder="请选择" multiple clearable @change="aa" ref="ff">
        <el-option
          v-for="item in options"
          :key="item.qq"
          :label="item.ll"
          :value="item.vv"
          :disabled="item.dd">
        </el-option>
      </el-select>
      <el-button @click="bb">焦点</el-button>
  </div>
</template>

<script>
  export default{
    name: "Select",
   data(){
     return{
       options: [{
                vv: '选项1',
                ll: '黄金糕',
                dd: true
              }, {
                vv: '选项2',
                ll: '双皮奶'
              }, {
                vv: '选项3',
                ll: '蚵仔煎'
              }, {
                vv: '选项4',
                ll: '龙须面'
              }, {
                vv: '选项5',
                ll: '北京烤鸭'
              }],
       asd: '',
       qwe: ','
     }
   },
   methods:{
     aa(value){
       console.log("咔咔咔咔咔咔");
       console.log(value);
       console.log(this.asd);
     },
     bb(){
       console.log("焦点方法触发");
       this.$refs.ff.focus();
     }
   }

  }
</script>

<style>
</style>
